-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resources StorageNodeSet and DatabaseNodeSet #169
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
kobzonega
force-pushed
the
YDBOPS-8646
branch
12 times, most recently
from
January 22, 2024 08:30
858c4de
to
94d65df
Compare
kobzonega
force-pushed
the
YDBOPS-8646
branch
2 times, most recently
from
January 22, 2024 08:59
d887fe7
to
720e1a1
Compare
kobzonega
force-pushed
the
YDBOPS-8646
branch
from
January 22, 2024 09:29
720e1a1
to
39bf223
Compare
artgromov
reviewed
Jan 23, 2024
kobzonega
force-pushed
the
YDBOPS-8646
branch
from
January 23, 2024 17:25
83db68f
to
c1705a5
Compare
artgromov
approved these changes
Jan 23, 2024
kobzonega
force-pushed
the
YDBOPS-8646
branch
from
January 23, 2024 20:49
c1705a5
to
5b7a3af
Compare
kobzonega
force-pushed
the
YDBOPS-8646
branch
from
January 23, 2024 21:12
5b7a3af
to
28549dc
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en
Pull request type
Please check the type of change your PR introduces:
What is the current behavior?
Storage/Database CR creates one StatefulSet k8s object which operated pods with YDB processes.
Issue Number: YDBOPS-8645, YDBOPS-8646
What is the new behavior?
We propose new CRDs (Custom Resource Definitions) named
StorageNodeSet
andDatabaseNodeSet
, which define the parameters of StatefulSets for a specific logical group of YDB nodes. The creation and modification of objects occur through the definition in the Storage/Database object, specifying parameters in thespec.nodeSet
field. Thus controller used in the ydb-operator performs the CRUD operation for *NodeSet CustomResource objects automatically.Performing Reconcile for NodeSet objects should include checking the presence of the StatefulSet resource, matching the desired quantity of replicas with the observed quantity. The status of parent objects when using *NodeSet is determined as the composition of readiness statuses StatefulSet and child Pod objects.
Operations related to interaction with the YDB cluster, such as Storage initialization, Tenant creation, SelfCheck verification, are performed in the Reconcile process for the Storage/Database object. For this purpose, in the parameters of StatefulSet objects created using NodeSet, the
spec.serviceName
(within one parent object) must be specified identically.Other information
Additional refactoring:
Update Makefile test scenarios to use existing kind cluster
Use new const variables
GRPCServiceFQDNFormat
andInterconnectServiceFQDNFormat
to build URL endpoint and domain stringsEdit const variable
DefaultDatabaseDomain
value from "root" to "Root"Remove database_defaults.go as useless (same logic as in kubebuilder webhook.Defaulter interface)
Use type
NamespacedRef
forStorageClusterRef
andDatabaseRef
fields in CustomResourcesAdd new field
StorageEndpoint
to Database and DatabaseNodeSet objects spec to define external FQDN for--node-broker
container argRemove useless
PublicHost
field in Database CR (use.spec.Service.GRPC.ExternalHost
and.spec.Service.Interconnect.ExternalHost
instead)Move YDB configuration build logic to a webhook so that it can be generated and specified when ydb-operator mutating API objects